package zut.cs.liziflower.mapper;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.ibatis.annotations.Param;
import zut.cs.liziflower.entity.Cart;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import zut.cs.liziflower.entity.Flower;

import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author xuwenke
 * @since 2022-05-19
 */
public interface CartMapper extends BaseMapper<Cart> {

    List<Flower> getCart(@Param("userid") Integer userid);

    //分页查询
    List<Flower> getPage(@Param("userid") Integer userid,
                         @Param("page") Integer page,
                         @Param("size") Integer size);

    int changeNumber(@Param("userid") Integer userid, @Param("flowerid") Integer flowerid, @Param("number") Integer number);


//    Page<Flower> page(@Param("userid") Integer userid,
//                         @Param("page") Integer page,
//                         @Param("size") Integer size);

}
